package com.gemme.gemme.view;

import android.content.Context;
import android.util.AttributeSet;
import android.view.LayoutInflater;
import android.view.View;
import android.widget.Button;
import android.widget.LinearLayout;
import android.widget.RelativeLayout;

import com.gemme.gemme.R;
import com.gemme.gemme.shequ.GuanzhuNewFragment;
import com.yanzhenjie.recyclerview.SwipeRecyclerView;

import androidx.recyclerview.widget.LinearLayoutManager;
import androidx.swiperefreshlayout.widget.SwipeRefreshLayout;

public class XuanTingView extends RelativeLayout {
    private Context context;
    public XuanTingView(Context context) {
        this(context,null);
    }

    public XuanTingView(Context context, AttributeSet attrs) {
        this(context, attrs,0);
    }

    public XuanTingView(Context context, AttributeSet attrs, int defStyleAttr) {
        super(context, attrs, defStyleAttr);
        this.context = context;
        initView();
    }

    LinearLayout ll_head;
    LinearLayout ll_middle;
    LinearLayout ll_bottom;
    private void initView() {
        LayoutInflater.from(context).inflate(R.layout.xuan_ting_view,this);
        ll_head = findViewById(R.id.ll_head);
        ll_middle = findViewById(R.id.ll_middle);
        ll_bottom = findViewById(R.id.ll_bottom);

    }




    public XuanTingView addHeadView(View headView){
        ll_head.addView(headView);
        return this;
    }
    public XuanTingView addMiddleView(View middleView){
        ll_middle.addView(middleView);
        return this;
    }
    public XuanTingView addBottomView(View middleView){
        ll_bottom.addView(middleView);
        return this;
    }

}
